<template>
  <!--  <img alt="Vue logo" src="./assets/logo.png">-->
  <!--  <HelloWorld msg="Welcome to Your Vue.js App"/>-->
  <!--  <router-link to="/index">Index</router-link>-->
  <!--  <router-link to="/session_one">Session One</router-link>-->
  <!-- <router-view></router-view> -->
  <viewMainWindow v-if="is_open_main_window" :sessionToken="sessionToken"></viewMainWindow>
  <indexSessionList v-if="!is_open_main_window"></indexSessionList>
</template>

<script>
// import HelloWorld from './components/HelloWorld.vue'
import viewMainWindow from "@/views/viewMainWindow";
import getPara from "@/utils/get_para_by_url";
import indexSessionList from "@/components/indexSessionList";

export default {
  name: 'App',
  components: {
    viewMainWindow,
    indexSessionList
    // HelloWorld,
  },
  data() {
    return {
      sessionToken: "202210071912078157",
      is_open_main_window: false
    }
  },
  methods: {
    sessionTokenVerify() {
      return this.sessionToken !== "";
    }
  },
  created: function () {
    this.sessionToken = getPara.getQueryString("sessionToken") || getPara.getHashString("sessionToken")
    if (this.sessionTokenVerify()) this.is_open_main_window = true
  },
}
</script>

<style>
#app {
  font-family: Avenir, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /*text-align: center;*/
  color: #2c3e50;
  /*margin-top: 60px;*/
}

::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0);
  border-radius: 0;
}

::-webkit-scrollbar {
  -webkit-appearance: none;
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-thumb {
  cursor: pointer;
  border-radius: 5px;
  background: rgba(153, 206, 198, 0.5);
  transition: color 0.2s ease;
}

::-webkit-scrollbar-thumb:hover {
  border-radius: 5px;
  background: rgba(117, 114, 82, 0.8);
}
</style>
